using System.Collections;
using System.Collections.Generic;
using Unity.Entities;
using Unity.Transforms;
using UnityEngine;

public partial struct PlayerMove : ISystem
{
    void OnUpdate(ref SystemState state)
    {
        
        if (Input.GetKey(KeyCode.Space))
        {
            foreach (var (transfrom, movedata) in SystemAPI.Query<RefRW<LocalTransform>, RefRW<Entityes_Player>>())
            {
                transfrom.ValueRW = transfrom.ValueRW.Translate(transfrom.ValueRW.Forward() * movedata.ValueRO.moveSpeed * SystemAPI.Time.DeltaTime);
            }
            Debug.Log("777");
        }
        Debug.Log("666");
    }
}
